import archive
import svn
import local

def retrieve(method, loc, path):
	if method is "archive": archive.download(loc, path)
	elif method is "svn": svn.checkout(loc, path)
	
	if method == "?":
		if loc.endswith('/'): 
			svn.checkout(loc, path)
		elif '.' not in loc[loc.rfind('/'):]: 
			svn.checkout(loc, path)
		elif not loc.startswith('http://'):
			local.copy(loc, path)
		else:
			archive.download(loc, path)
